<template>
	<view>
		<uni-card :title="'提交用户：' + this.$route.query.name" extra="">
			<text class="uni-body">
				<view class="title1">
					审核状态：{{this.$route.query.zhuangt}}
				</view>
				<br />
				<view class="title1">
					支付凭证：
				</view>
				<br />
				<cover-image :src="'http://127.0.0.1:8089/intool/' + this.$route.query.img"></cover-image>
			</text>
		</uni-card>
		<view class="tijiao">
			<button class="uni-btn" type="primary" @click="shen(1)" size="mini">通过</button>
			<button class="uni-btn" type="error" @click="shen(0)" size="mini">拒绝</button>
		</view>
	</view>
</template>

<script>
	import {
		baseDefaultUrl
	} from '../../config/config'
	export default {
		data() {
			return {

			}
		},
		onShow() {
			console.log(this.$route.query);
		},
		methods: {
			shen(statusw) {
				uni.request({
					url: baseDefaultUrl + "/inter/t-work/shen",
					method: 'GET',
					data: {
						"uwId": this.$route.query.id,
						"status": statusw
					},
					header: {
						"Authorization": uni.getStorageSync('token')
					},
					success: (res) => {
						if (res.data.code != 0) {
							uni.showToast({
								title: res.data.message,
								icon: 'success'
							});
						} else {
							uni.showToast({
								title: res.data.message,
								icon: 'error'
							});
						}
					}
				})
			},
		}
	}
</script>

<style scoped>
	.tijiao {
		padding: 10rpx 30rpx;
	}
</style>